//
//  ownCommodityModel.m
//  qqqqqq
//
//  Created by iOSer on 2017/3/20.
//  Copyright © 2017年 iOSer. All rights reserved.
//

#import "LEOwnCommodityModel.h"

@implementation LEOwnCommodityModel
-(void)setName:(NSString *)name{
    _name = name;
}
-(void)setCount:(int)count{
    _count = count;
}
-(void)setCosting:(long)costing{
    _costing = costing;
}
-(void)encodeWithCoder:(NSCoder *)aCoder{
    [aCoder encodeObject:self.name forKey:@"name"];
    [aCoder encodeObject:[NSNumber numberWithInt:self.count] forKey:@"count"];
    [aCoder encodeObject:[NSNumber numberWithLong:self.costing] forKey:@"costing"];
    
}
-(instancetype)initWithCoder:(NSCoder *)aDecoder{
    self = [[self class] new];
    if (self)
    {
        self.name = [aDecoder decodeObjectForKey:@"name"];
        self.count = [[aDecoder decodeObjectForKey:@"count"] intValue];
        self.costing = [[aDecoder decodeObjectForKey:@"costing"] longValue];
        
    }
    return self;
}


@end
